source 'https://rubygems.org'

git_source(:github) do |repo_name|
  repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
  "https://github.com/#{repo_name}.git"
end


# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.1.6'
# Use postgresql as the database for Active Record
gem 'pg'
gem 'pg_search'
# Use Puma as the app server
gem 'puma', '~> 3.7'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 2.5'
# Use Redis adapter to run Action Cable in production
gem 'redis', '~> 4.0'
# Use ActiveModel has_secure_password
gem 'bcrypt', '~> 3.1.7'
# 配置文件（多环境配置）
gem 'config', '~> 1.7'
# 软删除
gem 'paranoia', '~> 2.2'
# 分页
gem 'will_paginate', '~> 3.1.0'

# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development

# Use Rack CORS for handling Cross-Origin Resource Sharing (CORS), making cross-origin AJAX possible
# gem 'rack-cors'

group :development, :test do
  # Call 'byebug' anywhere in the code to stop execution and get a debugger console
  gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
  # 注释
  gem 'annotate'
  gem 'migration_comments'
  #  测试
  gem 'rspec-rails', '~> 3.7'
  gem 'airborne'
  gem 'shoulda-matchers', '~> 3.1'
  gem 'factory_bot_rails', '~> 4.0'
  gem 'ffaker', '~> 2.7'
  gem 'database_cleaner' #清除测试数据
  # 代码规范
  gem 'rails_best_practices', '~> 1.19', '>= 1.19.2'
end

group :development do
  gem 'listen', '>= 3.0.5', '< 3.2'
  # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
  gem 'spring'
  gem 'spring-watcher-listen', '~> 2.0.0'
  # 服务器部署
  gem 'mina'
  gem 'mina-puma', require: false
  gem 'mina-multistage', require: false
  gem 'mina-sidekiq'
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
